-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Correct FspInfoheader Assumption #10678
base: master
Are you sure you want to change the base?
Correct FspInfoheader Assumption #10678
Conversation
37e78bd
to
4234dce
Compare
; | ||
CALL_RDI ASM_PFX(AsmGetFspInfoHeaderNoStack) | ||
xor rsi, rsi | ||
mov rsi, rax |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mov esi, rax
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
corrected
; Get FspInfoHeader address | ||
; | ||
CALL_RDI ASM_PFX(AsmGetFspInfoHeaderNoStack) | ||
xor rsi, rsi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need the xor operation?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed as it is not necessary
4234dce
to
438cc3a
Compare
d0a92b1
to
7ef43c7
Compare
; | ||
; Get FspInfoHeader address | ||
; | ||
CALL_EDI ASM_PFX(AsmGetFspInfoHeaderNoStack) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
EAX holds FSP info header after LoadUpdPointerToECX called at line#602. We can save EAX to ESI at line#603 instead of calling AsmGetFspInfoHeaderNoStack here.
; | ||
; Get FspInfoHeader address | ||
; | ||
CALL_RDI ASM_PFX(AsmGetFspInfoHeaderNoStack) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can call AsmGetFspInfoHeaderNoStack and save RAX to RSI at line#450. By doing so, calling AsmGetFspInfoHeaderNoStack can be removed from line#460.
7ef43c7
to
b1884b1
Compare
It is assumed that the address of FspInfoheader is present in rsi while reading ImageAttribute. Reading and retrieving the FspInfoheader address to correct this. Signed-off-by: Aravind P R <[email protected]>
b1884b1
to
bff24b8
Compare
It is assumed that the address of FspInfoheader is present
in rsi while reading ImageAttirbute. Reading and retrieving
the FspInfoheader to correct this.
Signed-off-by: Aravind P R [email protected]
How This Was Tested
<Describe the test(s) that were run to verify the changes.>
Integration Instructions
<Describe how these changes should be integrated. Use N/A if nothing is required.>